import { createRouter, createWebHistory } from 'vue-router'
import App from '../App.vue'
import Login from '../views/login.vue'
import role from '../views/role.vue'
import home from '../views/Home.vue'
import list from '../views/List.vue'
import Approval from '../views/approval.vue'
import organize from '../views/organize.vue'
import Permissions from '../views/Permissions.vue'

import Detail from '../views/detail.vue'

// import Social from '../view/social.vue'
import Social from '../views/social.vue'
import SocialD from '../views/socialD.vue'
import Salary from '../views/salary.vue'
import Statement from '../views/statement.vue'

import Attendance from '../views/Attendance.vue'
import ditu from '../views/ditu.vue'


import staff from '../views/staff.vue'
const router = createRouter({
  history: createWebHistory(import.meta.env.BASE_URL),
  routes: [
    {
      path: '/',
      name: 'app',
      component: App,
      children: [
        {
          path: 'login',
          name: 'login',
          component: Login
        },
        {
          path: '/',
          name: 'home',
          component: home,
          children: [
            {
              path: 'role',
              name: 'role',
              component: role,
            },
            {
              path: 'list',
              name: 'list',
              component: list,
            },
            {
              path: 'approval',
              name: 'approval',
              component: Approval,
            },
            {
              path: 'organize',
              name: 'organize',
              component: organize,
            },
            {

              path: 'Permissions',
              name: 'Permissions',
              component: Permissions,
            },
            {
              path: 'detail',
              name: 'detail',
              component: Detail,
            },

            {
              path: 'social',
              name: 'social',
              component: Social,
            },
            {
              path: 'socialD',
              name: 'socialD',
              component: SocialD,
            },
            {
              path: 'salary',
              name: 'salary',
              component: Salary,
            },
            {
              path: 'statement',
              name: 'statement',
              component: Statement
            },

             {
              path: 'Attendance',
              name: 'dAttendance',
              component: Attendance,
            },

{

              path:'Permissions',
              name:'Permissions',
              component:Permissions,
            },
            {
              path:'staff',
              name:'staff',
              component:staff,
            },
             {
              path:'Attendance',
              name:'Attendance',
              component:Attendance,
            },
             

          ]
        },
        {
          path: 'ditu',
          name: 'ditu',
          component: ditu,
        },
      ]
    }

  ]
})

export default router
